package love.unknown.fruit.view;

import love.unknown.fruit.controller.Menu;

public class Client {
    public static void main(String[] args) {
        Menu m = new Menu();
        boolean flag = true;
        while (flag) {
            //显示主菜单
            int select = m.showMainMenu();
            switch (select) {
                case 1:
                    //显示库存列表
                    m.showFruitList();
                    break;
                case 2:
                    m.addFruit();
                    break;
                case 3:
                    m.showFruitInfo();
                    break;
                case 4:
                    m.delFruit();
                    break;
                case 5:
                    flag = m.exit();
                    break;
                default:
                    System.out.println("输入错误!");
            }
        }

    }
}
